import request from '@/utils/request'
export function menuApi() {
  return request({
    url: '/auth/menu',
    method: 'get',
  })
}
export const addRoleApi = (data) => {
  return request({
    url: '/auth/role',
    method: 'post',
    data
  })
}
export const getRoleInfoApi = (id) => {
  return request({
    url: '/auth/role/' + id,
    method: 'get',
  })
}
export const editRoleInfoApi = (data) => {
  return request({
    url: '/auth/role/' + data.id,
    method: 'put',
    data
  })
}
export const delRoleInfoApi = (id) => {
  return request({
    url: '/auth/role/' + id,
    method: 'delete'
  })
}
